package com.hisense.proxy.service.init;

import javax.annotation.PostConstruct;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

import com.hisense.proxy.service.utils.URLConfigEnum;

@Component
public class EnvConfigParamsInitializer {
	
	@Value("${yesfp.env.keypath}")
	private String keypath;
	
	@Value("${yesfp.env.password}")
	private String password;
	
	@Value("${yesfp.env.appid}")
	private String appid;
	
	@Value("${yesfp.env.domain}")
	private String domain;
	

	@PostConstruct
	public void init() {
		URLConfigEnum.APPID = appid;
		URLConfigEnum.KEY_PATH = keypath;
		URLConfigEnum.PASSWORD = password;
		URLConfigEnum.DOMAIN = domain;
	}
	
}
